Skip to content

Conversation

rjmunro
Copy link
Contributor

@rjmunro rjmunro commented Sep 10, 2025

About the Contributor

This pull request is posted on behalf of the BBC.

Type of Contribution

This is a Feature

Current Behavior

N/A

New Behavior

ActionContexts now contain a method getUpcomingParts which will return a list of upcoming parts after the next one, allowing actions to be taken based on what items may be coming up further ahead than the next part instance.

Testing

  • I have added one or more unit tests for this PR
  • I have updated the relevant unit tests
  • No unit test changes are needed for this PR

Affected areas

This PR affects what information is easily available to blueprints.

Time Frame

Other Information

Status

  • PR is ready to be reviewed.
  • The functionality has been tested by the author.
  • Relevant unit tests has been added / updated.
  • Relevant documentation (code comments, system documentation) has been added / updated.

@rjmunro rjmunro changed the base branch from main to release53 September 10, 2025 12:07
@rjmunro rjmunro changed the title Rjmunro/rundown in actions feat: Rundown information in actions Sep 10, 2025
Comment on lines 54 to 55
/** The max number of parts returned. */
limit?: number
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I like that the implementation of this interface has a reasonable default of 5, but I think the fact that there is a default has to be documented here (maybe not necessarily what the default is, but that there is a default?).

Alternatively, just mandating that you need to provide your own limit would be fine too, I think.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I've updated the JSDoc

So that an action can be taken based on what items may be coming up
(further ahead than the next part instance)
@rjmunro rjmunro force-pushed the rjmunro/rundown-in-actions branch from 08494df to 08942f8 Compare September 15, 2025 16:08
@codecov-commenter
Copy link

codecov-commenter commented Sep 15, 2025

⚠️ Please install the 'codecov app svg image' to ensure uploads and comments are reliably processed by Codecov.

Codecov Report

❌ Patch coverage is 80.00000% with 2 lines in your changes missing coverage. Please review.

Files with missing lines Patch % Lines
.../job-worker/src/blueprints/context/adlibActions.ts 60.00% 2 Missing ⚠️

📢 Thoughts on this report? Let us know!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

3 participants